<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<html>
<head>
<meta name="decorator" content="sysDefault" />
<title>铺位信息</title>
<link rel="stylesheet" type="text/css"
	href="${staticPath}/lib/jquery-ui-multiselect-widget-master/jquery.multiselect.css" />
<link rel="stylesheet" type="text/css"
	href="http://ajax.googleapis.com/ajax/libs/jqueryui/1/themes/redmond/jquery-ui.css" />
<script type="text/javascript"
	src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.js"></script>
<script type="text/javascript"
	src="http://ajax.googleapis.com/ajax/libs/jqueryui/1/jquery-ui.min.js"></script>
<script type="text/javascript"
	src="${staticPath}/lib/jquery-ui-multiselect-widget-master/src/jquery.multiselect.js"></script>
<script type="text/javascript"
	src="${staticPath}/js/selectBerth.js"></script>
</head>
<body>
	<h1>Form Submission Test</h1>
	<p>Testing to ensure the correct values are actually passed when
		the form is submitted.</p>

	<form action="#" method="post" style="margin-top: 20px">
<!-- 		<select id="berth" name="berth" multiple="multiple" size="5"> -->
<!-- 				<option value="1">--请选择--</option> -->
<!-- 		</select>  -->
		<div id="selectBerthDiv">
			
		</div>
	</form>

	
	<script type="text/javascript">

		$("form").bind("submit", function() {
			var intvalue = "";
			var o = document.getElementById("berth");
			for(var i=0;i<o.length;i++){   
				if(o.options[i].selected){
				    intvalue+=o.options[i].value+",";
				}
			}
			if(intvalue != ""){
				intvalue = intvalue.substr(0,intvalue.length-1);
			}
			return false;
		});
		
		$(document).ready(function (){
			selectBerth("1",'${contextPath}');
		});
		
	</script>
</body>
</html>